﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp2
{
    class Student : Person
    {
        private string major;
        private string grade;
        public Student() 
        {

        }
        public Student(string Major , int Grade) 
        {
            this.Major = major;
            this.Grade = grade;
        }
        public void Hello() 
        {
            base.Hello();
            Console.WriteLine("专业为{0}",this.major);
            Console.WriteLine("年级为{0}",this.grade);
        }
        public string Major 
        {
            get { return this.major; }
            set { this.major = value; }
        }
        public string Grade 
        {
            get { return this.grade; }
            set { this.grade = value; }
        }
    }
}
